Skip to content

Conversation

psteinroe
Copy link
Collaborator

What kind of change does this PR introduce?

closes #474

from #454 (comment)

@psteinroe psteinroe changed the title fix: add support for named param ala $name fix: add support for named param type $name Aug 12, 2025
match self.first() {
'$' => {
self.bump();
break self.dollar_quoted_string(start);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
break self.dollar_quoted_string(start);
return self.dollar_quoted_string(start);

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hat mich kurz irritiert, weil der breaked value ja auch aus der obrigen fn returned wird

start.push(c);
}
_ => {
break TokenKind::NamedParam {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
break TokenKind::NamedParam {
return TokenKind::NamedParam {

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this would actually behave differently. we need break, and the value is then returned from the loop. with return, we would return the value from the function.

@psteinroe psteinroe merged commit e2bbe42 into main Aug 14, 2025
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

add support for $name in the lexer
2 participants